import { createApp, provide } from 'vue'
import App from './App.vue'
import router from './router'
import '@/styles/element/index.scss'
import ElementPlus from 'element-plus'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import request from '@/utils/rerquest'


const app = createApp(App)
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
  }


// 注册全局变量

app.provide('global', {
  request,
  msg: '全局变量信息',
  baseUrl: import.meta.env.VITE_APP_BASEURL
})


app.use(ElementPlus)
app.use(router)
app.mount('#app')
